St Johnstone fought back to draw with Rangers, leaving the Ibrox side 16 points behind Scottish Premiership leaders Celtic.